<#escape x as (x)!"">
package ${basePackage}.${plate}.${modulePackage}.dto;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;

import com.fasterxml.jackson.annotation.JsonFormat;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

    /**
    * @公司:${corpName}
    * @功能:${functionCn} Model
    * @作者:${authName}
    * @日期:${datetime}
    * @版本:1.0
    * @修改:
    */ 

public class ${className}Model {

	public Set<String> colset = new HashSet<String>(0);
	
	<#if columns??>
		<#list columns as column>
        /*
        * ${column.comments}
        */
        <#if column.nullable="N" && column.isPkey ==false >
		<#if column.attrType="String">
		@NotEmpty(message = "${column.comments}不能为空")
		<#else>
		@NotNull(message = "${column .comments}不能为空")
		</#if>
		</#if>
		<#if column.inputType?? && column.inputType="date">
		@JsonFormat(pattern = "yyyy-MM-dd") 
		</#if>
	    private ${column.attrType} ${column.attrname};
		</#list>
	</#if>

        public ${className}Model(){

        }
        
	<#if columns??>
		<#list columns as column>
		/**
		 * 设置：${column.comments}
		 */
		public void set${column.attrName}(${column.attrType} ${column.attrname}) {
			colset.add("${column.attrname}");
			this.${column.attrname} = ${column.attrname};
		}
		/**
		 * 获取：${column.comments}
		 */
		public ${column.attrType} get${column.attrName}() {
			return ${column.attrname};
		}
		</#list>
	</#if>
}
</#escape>